﻿using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp23
{
    class Program
    {
        static void Main(string[] args)
        {
            Stack steck = new Stack();
            steck.Push(1);//向栈中添加元素1
            steck.Peek();//获取栈顶元素的值
            steck.Pop();//删除栈中顶元素的元素
            steck.Clear();//删除栈中所有的元素、
            steck.Contains(1);//判断栈中是否有1
            object[] obj = steck.ToArray();//复制栈到obj里
            Stack stack = new Stack();
            stack.Push("盘子1");
            stack.Push("盘子2");
            stack.Push("盘子3");
            while (stack.Count!=0) 
            {
                stack.Pop();
            }

        }
    }
}
